﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    class DeliveryRobot : Robot
    {
        private int hours;

        public int Hours { get => hours; set => hours = value; }

        public DeliveryRobot(string name, int hours) : base(name)
        {
            this.hours = hours;
        }

        public override void working()
        {
            Console.WriteLine("我叫{1}\n我可以传菜{0}小时", this.hours, this.Name);
        }
    }
}
